package unit4.part11;

import unit4.part10.Employer;
import unit4.part10.HR;

public class Leader extends Employer {
    public Leader(String name, int level, int salary) {
        super(name, level, salary);
    }

    public void appraise(Employer em) {
        if (em == this) {
            System.out.println("不能评价自己");
        } else if (em instanceof HR) {
            System.out.println(em.getName() + " 招聘工作干的不错");
        } else if (em instanceof Leader) {
            System.out.println(em.getName() + " 很棒");
        } else {
            System.out.println(em.getName() + " 工作认真");
        }
    }
}
